import numpy as np
test=np.load('D:/doctorTech/LIDC-IDRI-Preprocessing-master/LIDC-IDRI-Preprocessing-master/data/Image/LIDC-IDRI-0001/0001_NI000_slice007.npy',encoding = "latin1") #加载文件
print(type(test)) # 查看数据类型
doc = open('D:/1.txt', 'w')  # 打开一个存储文件，并依次写入
for i in range(len(test)):
    doc.write(str(test[i]) + '\n')
doc.close()